<template>
  <div class="container contract-review mb70">
    <p class="bread">
      <a href="#/index/cm-error-list" class="font-s-18">交易监控订单管理-首席监控师</a> >
      <a href="javascript:void(0);" class="font-s-16">详情</a>
    </p>
    <div class="content bg-c-fff">
      <h3 class="tc">交易监控流程图</h3>
      <div class="progress-box rel">
        <company-name-container :companyNames="companyNames"></company-name-container>
        <div class="line" :class="{center: companyNames.length===2}" :style="{height: (events.length+0.5)*90+60+'px'}">
          <div class="arrow"></div>
        </div>
        <event-item v-for="(item,index) in events" :key="index" :state="item.state" :totalSides="companyNames.length" :side="item.side" :content="item.content" :files="item.files"></event-item>
      </div>
      <p class="tc">交易监控结束</p>
    </div>
    <div class="content bg-c-fff">
      <h4> 备注信息：</h4>
      <div class="note-box">{{noteInformation}}</div>
    </div>
  </div>
</template>
<script type="text/javascript">
import CompanyNameContainer from '../components/CompanyNameContainer'
import EventItem from '../components/EventItem'
export default {
  components: {
    CompanyNameContainer,
    EventItem
  },
  data() {
    return {
      stepNum: 3,
      stepData: [{
        name: '查看资质审查报告'
      }, {
        name: '查看审查合同'
      }, {
        name: '监控师绘制流程图'
      }, {
        name: '监控员交易监控'
      }],
      companyNames: [{
        name: '甲方有限公司'
      }, {
        name: '乙方有限公司'
      }],
      noteInformation: '顶顶顶顶顶顶顶顶顶顶顶顶顶顶顶顶顶顶顶是离开父母今年；来看短发女生；1；上的来客给你发d；真是可怜发个美女上的来客给你们展示的；过来看吗；大量抗过敏vz；十大考古发掘；圣诞快乐方面；啊L法国电视看你们；ZSDKG你；是DLKG烦恼；LDSFHJ dfj:LFSDKnij收到两份；手里的开放明教；是贷款买房就；是对方可能是；地方快乐男声；的风格考试大纲和你说的；来看跟你说；的理工科女生；更看好你s；了放大看那',
      events: [{
        side: 0,
        files: [],
        content: '12312323123asdfasdf',
        state: 'done'
      }, {
        side: 1,
        files: [1],
        content: '12312323123asdfasdf',
        state: 'doing'
      }, {
        side: 0,
        files: [1, 2],
        content: '12312323123asdfasdf',
        state: 'todo'
      }, {
        side: 1,
        files: [1, 2, 3],
        content: '12312323123asdfasdf',
        state: 'todo'
      }, {
        side: 1,
        files: [1, 2, 3],
        content: '12312323123asdfasdf',
        state: 'todo'
      }]
    }
  }
}

</script>
<style type="text/css" scoped>
.content {
  padding-bottom: 30px;
  margin-top: 20px;
}

.content h3 {
  line-height: 40px;
  border-bottom: 1px solid #ddd;
}

.line {
  position: absolute;
  width: 2px;
  top: 0;
  left: 65px;
  margin-top: 10px;
  background-color: #cfcfcf;
}

.line.center {
  left: 50%;
}

.line .arrow {
  position: absolute;
  bottom: -10px;
  left: -7px;
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-top: 12px solid #cfcfcf;
}

.content p {
  margin-top: 50px;
}

.content h4 {
  padding-left: 30px;
  font-size: 14px;
  line-height: 30px;
  border-bottom: 1px solid #ddd;
}

.note-box {
  padding: 10px;
  text-indent: 20px;
  line-height: 30px;
}

</style>
